package com.activivety;

import android.app.Activity;
import android.os.Bundle;
import android.view.View;
import android.widget.AdapterView;
import android.widget.Button;
import android.widget.GridView;
import android.widget.Toast;
import android.widget.AdapterView.OnItemClickListener;

import com.adapter.ImgAdapter;
public class InfoAllCompany extends Activity {
	private String[] mStrings={
            "http://a3.twimg.com/profile_images/670625317/aam-logo-v3-twitter.png",
            "http://a3.twimg.com/profile_images/740897825/AndroidCast-350_normal.png",
            "http://a3.twimg.com/profile_images/121630227/Droid_normal.jpg",
            "http://a1.twimg.com/profile_images/957149154/twitterhalf_normal.jpg",
            "http://a1.twimg.com/profile_images/97470808/icon_normal.png",
            "http://a3.twimg.com/profile_images/511790713/AG.png",
          
            "http://a1.twimg.com/profile_images/97470808/icon_normal.png",
            "http://a3.twimg.com/profile_images/511790713/AG_normal.png",
            "http://a3.twimg.com/profile_images/956404323/androinica-avatar_normal.png",
            "http://a1.twimg.com/profile_images/909231146/Android_Biz_Man_normal.png",
            "http://a3.twimg.com/profile_images/72774055/AndroidHomme-LOGO_normal.jpg",
            "http://a1.twimg.com/profile_images/349012784/android_logo_small.jpg",
            "http://a1.twimg.com/profile_images/841338368/ea-twitter-icon_normal.png",
            "http://a3.twimg.com/profile_images/64827025/android-wallpaper6_2560x160_normal.png",
            "http://a3.twimg.com/profile_images/77641093/AndroidPlanet_normal.png"
    };
	private Button button;
	@Override
	   public void onCreate(Bundle savedInstanceState) {
	        super.onCreate(savedInstanceState);
	        setContentView(R.layout.info_all_company);
	        final GridView gridview = (GridView)findViewById(R.id.gridview_info_all_company);
	        button = (Button)findViewById(R.id.undo);
	        gridview.setAdapter(new ImgAdapter(this, mStrings));
	         
	        gridview.setOnItemClickListener(new OnItemClickListener() 
	        {
	            public void onItemClick(AdapterView<?> parent, View v, int position, long id) 
	            {                
	                Toast.makeText(getBaseContext(),"pic :" + (position + 1) + " selected", Toast.LENGTH_SHORT).show();
	              // launchMap();
	                finish();
	            }
	        });      
	         
	       
	         
	 
	    }
}
